﻿<ss:SlWindow x:Class="WorkSpace.UI.Controls.Windows.AssignWindow"
           xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation" 
           xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
           xmlns:sdk="http://schemas.microsoft.com/winfx/2006/xaml/presentation/sdk" 
           xmlns:controls="clr-namespace:System.Windows.Controls;assembly=System.Windows.Controls"
           xmlns:ss="clr-namespace:SmartSpace.UI.Silverlight;assembly=SmartSpace.UI.Silverlight"
           Width="400" Height="300" 
           Title="AssignWindow"
           Style="{StaticResource SlWindow}">
    <Grid x:Name="LayoutRoot" Margin="2">
        <Grid.RowDefinitions>
            <RowDefinition />
            <RowDefinition Height="Auto" />
        </Grid.RowDefinitions>
        <sdk:DataGrid Name="_ctlGrid" Grid.Row="0" AutoGenerateColumns="False">
            <sdk:DataGrid.Columns>
                <sdk:DataGridCheckBoxColumn Header="选择" Binding="{Binding Path=IsSelected, Mode=TwoWay}"/>
                <sdk:DataGridTextColumn Header="名称" Binding="{Binding Path=Data.Caption}" IsReadOnly="True"/>
            </sdk:DataGrid.Columns>
        </sdk:DataGrid>

        <StackPanel Grid.Row="1" Orientation="Horizontal" HorizontalAlignment="Center" Margin="5">
            <Button x:Name="OKButton" Content="确定" Click="OKButton_Click" Width="75" Height="25" Margin="0,0,3,0" />
            <Button x:Name="CancelButton" Content="取消" Click="CancelButton_Click" Width="75" Height="25" Margin="2,0,0,0" />
        </StackPanel>
    </Grid>
</ss:SlWindow>